<?php echo use_helper('Util'); ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <?php include_http_metas() ?>
    <?php include_metas() ?>
    <?php include_title() ?>
    <?php include_javascripts() ?>
    <?php include_stylesheets() ?>

    <link rel="shortcut icon" href="/favicon.ico" />
  </head>

  <body>
    <!-- start page -->
    <div id="page">
      <!-- start sidebar -->
      <div id="sidebar">
        <!-- menu -->
        <div class="menubg">

          <br />
          <ul class="menutab">
            <li class=""><?php echo link_to2("Feuilles d'heures", "salarie", array()); ?></li>

            <?php if ($sf_user->hasPermission("administration")) : ?>
              <li class=""><?php echo link_to_backend('Administration', 'homepage', array()); ?></li>
            <?php endif; ?>

            <?php if ($sf_user->isAuthenticated()) : ?>
              <li class=""><?php echo link_to2("Password", "password", array()); ?></li>
            <?php endif; ?>

            <li class="">
              <?php
              if ($sf_user->isAuthenticated())
                echo link_to2("Deconnexion", "sf_guard_signout", array());
              else
                echo link_to2("Connexion", "sf_guard_signin", array());
              ?>
            </li>
          </ul>
        </div>

        <!-- eventuellement, calendrier ici -->
        <?php if (has_slot('sidecal')) : ?>
          <?php include_slot('sidecal') ?>
        <?php endif ?>
      </div>
    </div>
    <!-- end sidebar -->

    <!-- start content -->
    <div id="content">
      <div id='notifications'>
        <?php if ($sf_user->hasFlash('notice')): ?>
          <div class="notice">
            <?php echo $sf_user->getFlash('notice') ?>
            <?php $sf_user->setFlash('notice', null) ?>
          </div>
          <script type='text/javascript'>
              setTimeout(function() { Effect.toggle($$('.notice').first(),'appear'); }, 1600)
          </script>
        <?php endif; ?>
      </div>
      
      <?php echo $sf_data->getRaw('sf_content'); ?>
    </div>
    <!-- end content -->
    </div>
  </body>
</html>
